<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3c.org/TR/1999/REC-html401-19991224/loose.dtd">
<html lang="en">
<head>
  <title>Haru Free PDF Library</title>
  <meta http-equiv="Content-Type"
 content="text/html; charset=iso-8859-1">
  <link href="default.css" type="text/css" rel="stylesheet">
</head>
<body>
<div id="headcontainer">
<div class="head"><img alt="Haru Free PDF Library"
 src="image/harulogo.png" style="width: 413px; height: 40px;"></div>
</div>
<div id="barcontainer">
<div class="buildbar"><a href="index.html">home</a> | <a
 href="http://sourceforge.net/project/showfiles.php?group_id=83044">download</a>
|
<a href="documentation.html">documentation</a> | <a
 href="examples.html">examples </a>| <a
 href="http://sourceforge.net/projects/libharu/">sourceforge</a> |
<a href="http://sourceforge.net/forum/?group_id=83044">forums</a><br>
</div>
</div>
<div id="container">
<div id="mainpage">
<div id="ccol">
<h2>Error Handling<br>
</h2>
<h3><a name="The_type_of_functions_"></a>The type of functions<br>
</h3>
<div class="bodytext1">There are three kind of functions in Haru.<br>
<br>
<table style="width: 100%; text-align: left;" border="1" cellpadding="1"
 cellspacing="1">
  <tbody>
    <tr>
      <td
 style="vertical-align: top; width: 20px; text-align: right; background-color: rgb(204, 204, 204);"><br>
      </td>
      <td
 style="vertical-align: top; background-color: rgb(204, 204, 204); width: 50%;">The
type of function<br>
      </td>
      <td
 style="vertical-align: top; background-color: rgb(204, 204, 204);">Retuen
value when an error occurred<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 20px; text-align: right;">1<br>
      </td>
      <td style="vertical-align: top; width: 50%;">The function whose
type of return parameter is HPDF_STATUS<br>
      </td>
      <td style="vertical-align: top;">It returns the code of error<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 20px; text-align: right;">2<br>
      </td>
      <td style="vertical-align: top; width: 50%;">The function which
returns the value<br>
      </td>
      <td style="vertical-align: top;">It returns the initial value<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 20px; text-align: right;">3</td>
      <td style="vertical-align: top; width: 50%;">The function which
retruns the handle of object<br>
      </td>
      <td style="vertical-align: top;">It return NULL<br>
      </td>
    </tr>
  </tbody>
</table>
<br>
When an error has occurred, an above return value is returned, and an
error
code is set to the document object. <br>
You can get an error code by invoking <a
 href="document_handling.html#HPDF_GetError_">HPDF_GetError()</a>.<br>
In addition, there are some functions which set a detailed error-code
with an error-code. The detailed error-code can be refered by invoking
HPDF_GetErrorDetail().<br>
<br>
However, when the first parameter of a function is invalid, the
error-code is not set (because the function cannot find a document
object that the error-code should be set).<br>
<br>
When a user-defined error function was set, the function is invoked
after an error-code is set.<br>
<br>
<div class="bodynote">Note:<br>
Once an error code is set, invoking some IO processing functions are
blocked. An application have to invoke HPDF_ResetError() to resume
program.<br>
</div>
<br>
</div>
<h3><a name="User-defined_error_handler_"></a>User-defined error handler<br>
</h3>
<div class="bodytext1">You can use user-defined error handler which is
invoked when an error occurred. <br>
The definition of an error handler is as follows.<br>
<br>
<div class="bodycode">#include "hpdf_types.h"<br>
<br>
typedef void<br>
(*HPDF_Error_Handler)&nbsp; (HPDF_STATUS&nbsp;&nbsp; error_no,<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
HPDF_STATUS&nbsp;&nbsp; detail_no,<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
void&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; *user_data);<br>
<br>
</div>
<br>
When you build Haru as shared library in Windows environment, The
definition is as follows.<br>
<div class="bodycode">#include "hpdf_types.h"<br>
<br>
typedef void<br>
(__stdcall *HPDF_Error_Handler)&nbsp; (HPDF_STATUS&nbsp;&nbsp; error_no,<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;
HPDF_STATUS&nbsp;&nbsp; detail_no,<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; &nbsp;&nbsp;&nbsp;&nbsp;
void&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; *user_data);<br>
<br>
</div>
<br>
<br>
</div>
<h3><a name="Effective_usage_of_a_user-defined_error_"></a>Effective
usage of a user-defined error handler<br>
</h3>
<div class="bodytext1">You can perform error processing effectively by
using an error handler.<br>
<br>
<span style="font-weight: bold;">1. The typical usage of error handler
on C</span><br>
<br>
<div class="bodytext5">
C language does not support an exception feature, but with emulating an
exception handling by using setjmp/longjmp macro, the error handling
becomes simple.<br>
<br>
<div class="bodycode"><span style="font-weight: bold;">&nbsp; void</span><br>
&nbsp; error_handler (HPDF_STATUS&nbsp;&nbsp; error_no,<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
HPDF_STATUS&nbsp;&nbsp; detail_no,<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<span style="font-weight: bold;">void&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
</span>*user_data)<br>
&nbsp; {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="color: rgb(0, 153, 0);">/*
invoke longjmp() when an error has occurred */</span><br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; printf ("ERROR: error_no=%04X,
detail_no=%d\n", (<span style="font-weight: bold;">unsigned int</span>)error_no,&nbsp;&nbsp;&nbsp;&nbsp;
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (<span
 style="font-weight: bold;">int</span>)detail_no);<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; longjmp(env, 1);<br>
&nbsp; }<br>
<br>
&nbsp; <span style="font-weight: bold;">int </span>main () <br>
&nbsp; {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="color: rgb(0, 153, 0);">/*
set error-handler when creating a PDF_Doc object */</span><br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; HPDF_Doc pdf;<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; pdf = HPDF_New (error_handler, <span
 style="font-weight: bold;">NULL</span>);<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-weight: bold;">if </span>(!pdf)
{<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; printf ("error:
cannot create PdfDoc object\n");<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span
 style="font-weight: bold;">return </span>1;<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-weight: bold;">if </span>(setjmp(env))
{<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; HPDF_Free (pdf);<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span
 style="font-weight: bold;">return </span>1;<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="color: rgb(0, 153, 0);">/*
do page description processes</span><br style="color: rgb(0, 153, 0);">
<span style="color: rgb(0, 153, 0);">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
* (we do not have to check the return code of functions) </span><br
 style="color: rgb(0, 153, 0);">
<span style="color: rgb(0, 153, 0);">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
*/</span><br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="color: rgb(0, 153, 0);">/*
save the document to a file */</span><br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; HPDF_SaveToFile (pdf, fname);<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="color: rgb(0, 153, 0);">/*
clean up */</span><br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; HPDF_Free (pdf);<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-weight: bold;">return
</span>0;<br>
&nbsp; }<br>
<br>
</div>
<br>
<br>
</div>
<span style="font-weight: bold;">2. The typical usage of error handler
on C++</span><br>
<br>
<div class="bodytext5">
C++ supports an exception feature. Error processing becomes simple by
throwing an exception when an error has occurred.<br>
<br>
<div class="bodycode"><span style="font-weight: bold;">&nbsp; void</span><br>
&nbsp; error_handler (HPDF_STATUS&nbsp;&nbsp; error_no,<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
HPDF_STATUS&nbsp;&nbsp; detail_no,<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<span style="font-weight: bold;">void&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
</span>*user_data)<br>
&nbsp; {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="color: rgb(0, 153, 0);">/*
throw exception when an error has occured */</span><br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; printf ("ERROR: error_no=%04X,
detail_no=%d\n", (<span style="font-weight: bold;">unsigned int</span>)error_no,&nbsp;&nbsp;&nbsp;&nbsp;
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; (<span
 style="font-weight: bold;">int</span>)detail_no);<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-weight: bold;">throw </span>std::exception
();<br>
&nbsp; }<br>
<br>
&nbsp; <span style="font-weight: bold;">int </span>main () <br>
&nbsp; {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="color: rgb(0, 153, 0);">/*
set error-handler when creating a PDF_Doc object&nbsp; */</span><br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; HPDF_Doc pdf = HPDF_New (error_handler, <span
 style="font-weight: bold;">NULL</span>);<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-weight: bold;">if </span>(!pdf)
{<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; printf ("error:
cannot create PdfDoc object\n");<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span
 style="font-weight: bold;">return </span>1;<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span style="font-weight: bold;">try </span>{<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span
 style="color: rgb(0, 153, 0);">/* do page description processes</span><br
 style="color: rgb(0, 153, 0);">
<span style="color: rgb(0, 153, 0);">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
* (we do not have to check the return code of functions) </span><br
 style="color: rgb(0, 153, 0);">
<span style="color: rgb(0, 153, 0);">&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
*/</span><br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span
 style="color: rgb(0, 153, 0);">/* save the document to a file */</span><br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; HPDF_SaveToFile
(pdf, fname);<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; } <span
 style="font-weight: bold;">catch</span> (...) {<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
HPDF_Free (pdf);<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<span style="font-weight: bold;">return </span>1;<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span
 style="color: rgb(0, 153, 0);">/* clean up */</span><br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; HPDF_Free (pdf);<br>
<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; <span
 style="font-weight: bold;">return </span>0;<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; }<br>
&nbsp;&nbsp;&nbsp; }<br>
<br>
</div>
<br>
<br>
</div>
<span style="font-weight: bold;">3. Other programing languages<br>
<br>
</span>
<div class="bodytext5">In the case of languages supporting an exception
handling, you can handle an error in a similar way. In the case of the
languages which does not support an exception handling, you have to
check return code after invoking functions.<br>
There are wrapper programs for Ruby,Delphi and C# in "if" directory.
Refer
these source-code.<br>
<br>
</div>
</div>
<h3><a name="Finalization_and_cleanup_"></a>Finalization and cleanup<br>
</h3>
<div class="bodytext1">Do not forget to invoke <a
 href="document_handling.html#HPDF_Free_">HPDF_Free()</a> in any case.<br>
As a result, it is guaranteed that the allocated memory is surely
freed. <br>
</div>
<br>
<h3><a name="The_list_of_error_code_"></a>List of error code<br>
</h3>
<div class="bodytext1"><br>
<table style="width: 100%; text-align: left;" border="1" cellpadding="1"
 cellspacing="1">
  <tbody>
    <tr>
      <td
 style="vertical-align: top; width: 24px; text-align: right; background-color: rgb(204, 204, 204);"><br>
      </td>
      <td
 style="vertical-align: top; width: 280px; background-color: rgb(204, 204, 204);">Name<br>
      </td>
      <td
 style="vertical-align: top; width: 50px; background-color: rgb(204, 204, 204);">Value<br>
      </td>
      <td
 style="vertical-align: top; background-color: rgb(204, 204, 204);">Description<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">1<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_ARRAY_COUNT_ERR</td>
      <td style="vertical-align: top; width: 50px;">0x1001</td>
      <td style="vertical-align: top;">Internal error. The consistency
of the data was lost. <br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">2<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_ARRAY_ITEM_NOT_FOUND</td>
      <td style="vertical-align: top; width: 50px;">0x1002</td>
      <td style="vertical-align: top;">Internal error. The consistency
of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">3<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_ARRAY_ITEM_UNEXPECTED_TYPE</td>
      <td style="vertical-align: top; width: 50px;">0x1003</td>
      <td style="vertical-align: top;">Internal error. The consistency
of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">4<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_BINARY_LENGTH_ERR</td>
      <td style="vertical-align: top; width: 50px;">0x1004</td>
      <td style="vertical-align: top;">The length of the data exceeds
HPDF_LIMIT_MAX_STRING_LEN.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">5<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_CANNOT_GET_PALLET</td>
      <td style="vertical-align: top; width: 50px;">0x1005</td>
      <td style="vertical-align: top;">Cannot get a pallet data from
PNG image. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">6<br>
      </td>
      <td style="vertical-align: top; width: 280px;"><br>
      </td>
      <td style="vertical-align: top; width: 50px;">0x1006</td>
      <td style="vertical-align: top;"><br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">7<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_DICT_COUNT_ERR</td>
      <td style="vertical-align: top; width: 50px;">0x1007</td>
      <td style="vertical-align: top;">The count of elements of a
dictionary exceeds HPDF_LIMIT_MAX_DICT_ELEMENT<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">8<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_DICT_ITEM_NOT_FOUND</td>
      <td style="vertical-align: top; width: 50px;">0x1008</td>
      <td style="vertical-align: top;">Internal error. The consistency
of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">9<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_DICT_ITEM_UNEXPECTED_TYPE</td>
      <td style="vertical-align: top; width: 50px;">0x1009</td>
      <td style="vertical-align: top;">Internal error. The consistency
of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">10<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_DICT_STREAM_LENGTH_NOT_FOUND</td>
      <td style="vertical-align: top; width: 50px;">0x100A</td>
      <td style="vertical-align: top;">Internal error. The consistency
of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">11<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_DOC_ENCRYPTDICT_NOT_FOUND</td>
      <td style="vertical-align: top; width: 50px;">0x100B</td>
      <td style="vertical-align: top;">HPDF_SetPermission() OR
HPDF_SetEncryptMode() was called before a password is set.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">12<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_DOC_INVALID_OBJECT</td>
      <td style="vertical-align: top; width: 50px;">0x100C</td>
      <td style="vertical-align: top;">Internal error. The consistency
of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">13<br>
      </td>
      <td style="vertical-align: top; width: 280px;"><br>
      </td>
      <td style="vertical-align: top; width: 50px;">0x100D</td>
      <td style="vertical-align: top;"><br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">14<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_DUPLICATE_REGISTRATION</td>
      <td style="vertical-align: top; width: 50px;">0x100E</td>
      <td style="vertical-align: top;">Tried to register a font that
has been registered. <br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">15<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_EXCEED_JWW_CODE_NUM_LIMIT<br>
      </td>
      <td style="vertical-align: top; width: 50px;">0x100F</td>
      <td style="vertical-align: top;">Cannot register a character to
the japanese word wrap characters list.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">16<br>
      </td>
      <td style="vertical-align: top; width: 280px;"><br>
      </td>
      <td style="vertical-align: top; width: 50px;">0x1010</td>
      <td style="vertical-align: top;"><br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">17<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_ENCRYPT_INVALID_PASSWORD</td>
      <td style="vertical-align: top; width: 50px;">0x1011</td>
      <td style="vertical-align: top;">Tried to set the owner password
to NULL.<br>
The owner password and user password is the same. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">18<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_ERR_UNKNOWN_CLASS</td>
      <td style="vertical-align: top; width: 50px;">0x1013</td>
      <td style="vertical-align: top;">Internal error. The consistency
of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">19<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_EXCEED_GSTATE_LIMIT</td>
      <td style="vertical-align: top; width: 50px;">0x1014</td>
      <td style="vertical-align: top;">The depth of the stack exceeded
HPDF_LIMIT_MAX_GSTATE.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">20<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_FAILD_TO_ALLOC_MEM</td>
      <td style="vertical-align: top; width: 50px;">0x1015</td>
      <td style="vertical-align: top;">Memory allocation failed.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">21<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_FILE_IO_ERROR</td>
      <td style="vertical-align: top; width: 50px;">0x1016</td>
      <td style="vertical-align: top;">File processing failed. (A
detailed code is set.)<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">22<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_FILE_OPEN_ERROR</td>
      <td style="vertical-align: top; width: 50px;">0x1017</td>
      <td style="vertical-align: top;">Cannot open a file. (A detailed
code is set.)<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">23<br>
      </td>
      <td style="vertical-align: top; width: 280px;"><br>
      </td>
      <td style="vertical-align: top; width: 50px;">0x1018</td>
      <td style="vertical-align: top;"><br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">24<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_FONT_EXISTS</td>
      <td style="vertical-align: top; width: 50px;">0x1019</td>
      <td style="vertical-align: top;">Tried to load a font that has
been registered. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">25<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_FONT_INVALID_WIDTHS_TABLE</td>
      <td style="vertical-align: top; width: 50px;">0x101A</td>
      <td style="vertical-align: top;">The format of a font-file is
invalid .<br>
Internal error. The consistency of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">26<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_AFM_HEADER</td>
      <td style="vertical-align: top; width: 50px;">0x101B</td>
      <td style="vertical-align: top;">Cannot recognize a header of an
afm file.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">27<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_ANNOTATION</td>
      <td style="vertical-align: top; width: 50px;">0x101C</td>
      <td style="vertical-align: top;">The specified annotation handle
is invalid. <br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">28<br>
      </td>
      <td style="vertical-align: top; width: 280px;"><br>
      </td>
      <td style="vertical-align: top; width: 50px;">0x101D</td>
      <td style="vertical-align: top;"><br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">29<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_BIT_PER_COMPONENT</td>
      <td style="vertical-align: top; width: 50px;">0x101E</td>
      <td style="vertical-align: top;">Bit-per-component of a image
which was set as mask-image is invalid.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">30<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_CHAR_MATRICS_DATA</td>
      <td style="vertical-align: top; width: 50px;">0x101F</td>
      <td style="vertical-align: top;">Cannot recognize
char-matrics-data&nbsp; of an afm file. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">31<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_COLOR_SPACE</td>
      <td style="vertical-align: top; width: 50px;">0x1020</td>
      <td style="vertical-align: top;">1. The color_space parameter of
HPDF_LoadRawImage is invalid.<br>
2. Color-space of a image which was set as mask-image is invalid.<br>
3. The function which is invalid in the present color-space was invoked.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">32<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_COMPRESSION_MODE</td>
      <td style="vertical-align: top; width: 50px;">0x1021</td>
      <td style="vertical-align: top;">Invalid value was set when
invoking HPDF_SetCommpressionMode().<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">33<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_DATE_TIME</td>
      <td style="vertical-align: top; width: 50px;">0x1022</td>
      <td style="vertical-align: top;">An invalid date-time value was
set.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">34<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_DESTINATION</td>
      <td style="vertical-align: top; width: 50px;">0x1023</td>
      <td style="vertical-align: top;">An invalid destination handle
was set.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">35<br>
      </td>
      <td style="vertical-align: top; width: 280px;"><br>
      </td>
      <td style="vertical-align: top; width: 50px;">0x1024</td>
      <td style="vertical-align: top;"><br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">36<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_DOCUMENT</td>
      <td style="vertical-align: top; width: 50px;">0x1025</td>
      <td style="vertical-align: top;">An invalid document handle is
set. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">37<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_DOCUMENT_STATE</td>
      <td style="vertical-align: top; width: 50px;">0x1026</td>
      <td style="vertical-align: top;">The function which is invalid in
the present state was invoked. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">38<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_ENCODER</td>
      <td style="vertical-align: top; width: 50px;">0x1027</td>
      <td style="vertical-align: top;">An invalid encoder handle is
set. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">39<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_ENCODER_TYPE</td>
      <td style="vertical-align: top; width: 50px;">0x1028</td>
      <td style="vertical-align: top;">A combination between font and
encoder is wrong.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">40<br>
      </td>
      <td style="vertical-align: top; width: 280px;"><br>
      </td>
      <td style="vertical-align: top; width: 50px;">0x1029</td>
      <td style="vertical-align: top;"><br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">41<br>
      </td>
      <td style="vertical-align: top; width: 280px;"><br>
      </td>
      <td style="vertical-align: top; width: 50px;">0x102A</td>
      <td style="vertical-align: top;"><br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">42<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_ENCODING_NAME</td>
      <td style="vertical-align: top; width: 50px;">0x102B</td>
      <td style="vertical-align: top;">An Invalid encoding name is
specified.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">43<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_ENCRYPT_KEY_LEN</td>
      <td style="vertical-align: top; width: 50px;">0x102C</td>
      <td style="vertical-align: top;">The lengh of the key of
encryption is invalid.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">44<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_FONTDEF_DATA</td>
      <td style="vertical-align: top; width: 50px;">0x102D</td>
      <td style="vertical-align: top;">1. An invalid font handle was
set.<br>
2. Unsupported font format.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">45<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_FONTDEF_TYPE</td>
      <td style="vertical-align: top; width: 50px;">0x102E</td>
      <td style="vertical-align: top;">Internal error. The consistency
of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">46<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_FONT_NAME</td>
      <td style="vertical-align: top; width: 50px;">0x102F</td>
      <td style="vertical-align: top;">A font which has the specified
name is not found.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">47<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_IMAGE</td>
      <td style="vertical-align: top; width: 50px;">0x1030</td>
      <td style="vertical-align: top;">Unsupported image format.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">48<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_JPEG_DATA</td>
      <td style="vertical-align: top; width: 50px;">0x1031</td>
      <td style="vertical-align: top;">Unsupported image format. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">49<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_N_DATA</td>
      <td style="vertical-align: top; width: 50px;">0x1032</td>
      <td style="vertical-align: top;">Cannot read a postscript-name
from an afm file. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">50<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_OBJECT</td>
      <td style="vertical-align: top; width: 50px;">0x1033</td>
      <td style="vertical-align: top;">1. An invalid object is set.<br>
2. Internal error. The consistency of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">51<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_OBJ_ID</td>
      <td style="vertical-align: top; width: 50px;">0x1034</td>
      <td style="vertical-align: top;"> Internal error. The consistency
of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">52<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_OPERATION</td>
      <td style="vertical-align: top; width: 50px;">0x1035</td>
      <td style="vertical-align: top;">1. Invoked
HPDF_Image_SetColorMask() against the image-object which was set a
mask-image.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">53<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_OUTLINE</td>
      <td style="vertical-align: top; width: 50px;">0x1036</td>
      <td style="vertical-align: top;">An invalid outline-handle was
specified.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">54<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_PAGE</td>
      <td style="vertical-align: top; width: 50px;">0x1037</td>
      <td style="vertical-align: top;">An invalid page-handle was
specified.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">55<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_PAGES</td>
      <td style="vertical-align: top; width: 50px;">0x1038</td>
      <td style="vertical-align: top;">An invalid pages-handle was
specified. (internel error)<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">56<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_PARAMETER</td>
      <td style="vertical-align: top; width: 50px;">0x1039</td>
      <td style="vertical-align: top;">An invalid value is set.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">57<br>
      </td>
      <td style="vertical-align: top; width: 280px;"><br>
      </td>
      <td style="vertical-align: top; width: 50px;">0x103A</td>
      <td style="vertical-align: top;"><br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">58<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_PNG_IMAGE</td>
      <td style="vertical-align: top; width: 50px;">0x103B</td>
      <td style="vertical-align: top;">Invalid PNG image format. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">59<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_STREAM</td>
      <td style="vertical-align: top; width: 50px;">0x103C</td>
      <td style="vertical-align: top;"> Internal error. The consistency
of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">60<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_MISSING_FILE_NAME_ENTRY<br>
      </td>
      <td style="vertical-align: top; width: 50px;">0x103D</td>
      <td style="vertical-align: top;"> Internal error. The
"_FILE_NAME" entry for delayed loading is missing. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">61<br>
      </td>
      <td style="vertical-align: top; width: 280px;"><br>
      </td>
      <td style="vertical-align: top; width: 50px;">0x103E</td>
      <td style="vertical-align: top;"><br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">62<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_TTC_FILE</td>
      <td style="vertical-align: top; width: 50px;">0x103F</td>
      <td style="vertical-align: top;">Invalid .TTC file format.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">63<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_TTC_INDEX</td>
      <td style="vertical-align: top; width: 50px;">0x1040</td>
      <td style="vertical-align: top;">The index parameter was exceed
the number of included fonts<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">64<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_WX_DATA</td>
      <td style="vertical-align: top; width: 50px;">0x1041</td>
      <td style="vertical-align: top;">Cannot read a width-data from an
afm file. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">65<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_ITEM_NOT_FOUND</td>
      <td style="vertical-align: top; width: 50px;">0x1042</td>
      <td style="vertical-align: top;"> Internal error. The consistency
of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">66<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_LIBPNG_ERROR</td>
      <td style="vertical-align: top; width: 50px;">0x1043</td>
      <td style="vertical-align: top;">An error has returned from
PNGLIB while loading an image.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">67<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_NAME_INVALID_VALUE</td>
      <td style="vertical-align: top; width: 50px;">0x1044</td>
      <td style="vertical-align: top;"> Internal error. The consistency
of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">68<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_NAME_OUT_OF_RANGE</td>
      <td style="vertical-align: top; width: 50px;">0x1045</td>
      <td style="vertical-align: top;"> Internal error. The consistency
of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">69<br>
      </td>
      <td style="vertical-align: top; width: 280px;"><br>
      </td>
      <td style="vertical-align: top; width: 50px;">0x1046</td>
      <td style="vertical-align: top;"><br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">70<br>
      </td>
      <td style="vertical-align: top; width: 280px;"><br>
      </td>
      <td style="vertical-align: top; width: 50px;">0x1047</td>
      <td style="vertical-align: top;"><br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">71<br>
      </td>
      <td style="vertical-align: top; width: 280px;"><br>
      </td>
      <td style="vertical-align: top; width: 50px;">0x1048</td>
      <td style="vertical-align: top;"><br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">72<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_PAGES_MISSING_KIDS_ENTRY</td>
      <td style="vertical-align: top; width: 50px;">0x1049</td>
      <td style="vertical-align: top;"> Internal error. The consistency
of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">73<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_PAGE_CANNOT_FIND_OBJECT</td>
      <td style="vertical-align: top; width: 50px;">0x104A</td>
      <td style="vertical-align: top;"> Internal error. The consistency
of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">74<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_PAGE_CANNOT_GET_ROOT_PAGES</td>
      <td style="vertical-align: top; width: 50px;">0x104B</td>
      <td style="vertical-align: top;"> Internal error. The consistency
of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">75<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_PAGE_CANNOT_RESTORE_GSTATE</td>
      <td style="vertical-align: top; width: 50px;">0x104C</td>
      <td style="vertical-align: top;">There are no graphics-states to
be restored.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">76<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_PAGE_CANNOT_SET_PARENT</td>
      <td style="vertical-align: top; width: 50px;">0x104D</td>
      <td style="vertical-align: top;"> Internal error. The consistency
of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">77<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_PAGE_FONT_NOT_FOUND</td>
      <td style="vertical-align: top; width: 50px;">0x104E</td>
      <td style="vertical-align: top;">The current font is not set.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">78<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_PAGE_INVALID_FONT</td>
      <td style="vertical-align: top; width: 50px;">0x104F</td>
      <td style="vertical-align: top;">An invalid font-handle was
spacified.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">79<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_PAGE_INVALID_FONT_SIZE</td>
      <td style="vertical-align: top; width: 50px;">0x1050</td>
      <td style="vertical-align: top;">An invalid font-size was set.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">80<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_PAGE_INVALID_GMODE</td>
      <td style="vertical-align: top; width: 50px;">0x1051</td>
      <td style="vertical-align: top;">See <a
 href="graphics.html#Graphics_mode_">Graphics mode</a>.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">81<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_PAGE_INVALID_INDEX</td>
      <td style="vertical-align: top; width: 50px;">0x1052</td>
      <td style="vertical-align: top;"> Internal error. The consistency
of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">82<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_PAGE_INVALID_ROTATE_VALUE</td>
      <td style="vertical-align: top; width: 50px;">0x1053</td>
      <td style="vertical-align: top;">The specified value is not a
multiple of 90. <br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">83<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_PAGE_INVALID_SIZE</td>
      <td style="vertical-align: top; width: 50px;">0x1054</td>
      <td style="vertical-align: top;">An invalid page-size was set. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">84<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_PAGE_INVALID_XOBJECT</td>
      <td style="vertical-align: top; width: 50px;">0x1055</td>
      <td style="vertical-align: top;">An invalid image-handle was set.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">85<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_PAGE_OUT_OF_RANGE</td>
      <td style="vertical-align: top; width: 50px;">0x1056</td>
      <td style="vertical-align: top;">The specified value is out of
range.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">86<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_REAL_OUT_OF_RANGE</td>
      <td style="vertical-align: top; width: 50px;">0x1057</td>
      <td style="vertical-align: top;">The specified value is out of
range. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">87<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_STREAM_EOF</td>
      <td style="vertical-align: top; width: 50px;">0x1058</td>
      <td style="vertical-align: top;">Unexpected EOF marker was
detected.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">88<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_STREAM_READLN_CONTINUE</td>
      <td style="vertical-align: top; width: 50px;">0x1059</td>
      <td style="vertical-align: top;"> Internal error. The consistency
of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">89<br>
      </td>
      <td style="vertical-align: top; width: 280px;"><br>
      </td>
      <td style="vertical-align: top; width: 50px;">0x105A</td>
      <td style="vertical-align: top;"><br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">90<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_STRING_OUT_OF_RANGE</td>
      <td style="vertical-align: top; width: 50px;">0x105B</td>
      <td style="vertical-align: top;">The length of the specified text
is too long.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">91<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_THIS_FUNC_WAS_SKIPPED</td>
      <td style="vertical-align: top; width: 50px;">0x105C</td>
      <td style="vertical-align: top;">The execution of a function was
skipped because of other errors.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">92<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_TTF_CANNOT_EMBEDDING_FONT</td>
      <td style="vertical-align: top; width: 50px;">0x105D</td>
      <td style="vertical-align: top;">This font cannot be embedded.
(restricted by license)<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">93<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_TTF_INVALID_CMAP</td>
      <td style="vertical-align: top; width: 50px;">0x105E</td>
      <td style="vertical-align: top;">Unsupported ttf format. (cannot
find unicode cmap.)<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">94<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_TTF_INVALID_FOMAT</td>
      <td style="vertical-align: top; width: 50px;">0x105F</td>
      <td style="vertical-align: top;">Unsupported ttf format. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">95<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_TTF_MISSING_TABLE</td>
      <td style="vertical-align: top; width: 50px;">0x1060</td>
      <td style="vertical-align: top;">Unsupported ttf format. (cannot
find a necessary table) </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">96<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_UNSUPPORTED_FONT_TYPE</td>
      <td style="vertical-align: top; width: 50px;">0x1061</td>
      <td style="vertical-align: top;"> Internal error. The consistency
of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">97<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_UNSUPPORTED_FUNC</td>
      <td style="vertical-align: top; width: 50px;">0x1062</td>
      <td style="vertical-align: top;"> 1. The library is not
configured to use PNGLIB.<br>
2. Internal error. The consistency of the data was lost.</td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">98<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_UNSUPPORTED_JPEG_FORMAT</td>
      <td style="vertical-align: top; width: 50px;">0x1063</td>
      <td style="vertical-align: top;">Unsupported Jpeg format. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">99<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_UNSUPPORTED_TYPE1_FONT</td>
      <td style="vertical-align: top; width: 50px;">0x1064</td>
      <td style="vertical-align: top;">Failed to parse .PFB file.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">100<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_XREF_COUNT_ERR</td>
      <td style="vertical-align: top; width: 50px;">0x1065</td>
      <td style="vertical-align: top;">Internal error. The consistency
of the data was lost. </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">101<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_ZLIB_ERROR</td>
      <td style="vertical-align: top; width: 50px;">0x1066</td>
      <td style="vertical-align: top;">An error has occurred while
executing a function of Zlib.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">102<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_PAGE_INDEX</td>
      <td style="vertical-align: top; width: 50px;">0x1067</td>
      <td style="vertical-align: top;">An error returned from Zlib.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">103<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_URI</td>
      <td style="vertical-align: top; width: 50px;">0x1068</td>
      <td style="vertical-align: top;">An invalid URI was set.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">104<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_PAGELAYOUT_OUT_OF_RANGE</td>
      <td style="vertical-align: top; width: 50px;">0x1069</td>
      <td style="vertical-align: top;">An invalid page-layout was set.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">105<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_PAGEMODE_OUT_OF_RANGE</td>
      <td style="vertical-align: top; width: 50px;">0x1070</td>
      <td style="vertical-align: top;">An invalid page-mode was set.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">106<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_PAGENUM_STYLE_OUT_OF_RANGE</td>
      <td style="vertical-align: top; width: 50px;">0x1071</td>
      <td style="vertical-align: top;">An invalid page-num-style was
set.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">107<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_ANNOT_INVALID_ICON</td>
      <td style="vertical-align: top; width: 50px;">0x1072</td>
      <td style="vertical-align: top;">An invalid icon was set.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">108<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_ANNOT_INVALID_BORDER_STYLE</td>
      <td style="vertical-align: top; width: 50px;">0x1073</td>
      <td style="vertical-align: top;">An invalid border-style was set.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">109<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_PAGE_INVALID_DIRECTION</td>
      <td style="vertical-align: top; width: 50px;">0x1074</td>
      <td style="vertical-align: top;">An invalid page-direction was
set.<br>
      </td>
    </tr>
    <tr>
      <td style="vertical-align: top; width: 24px; text-align: right;">110<br>
      </td>
      <td style="vertical-align: top; width: 280px;">HPDF_INVALID_FONT</td>
      <td style="vertical-align: top; width: 50px;">0x1075</td>
      <td style="vertical-align: top;">An invalid font-handle was
specified.<br>
      </td>
    </tr>
  </tbody>
</table>
<br>
</div>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
</div>
</div>
<div id="lcol">
<div class="sidebar">
<ul>
</ul>
<ul>
  <li> <a href="#The_type_of_functions_">The type of functions</a> </li>
  <li><a href="#User-defined_error_handler_">User-defined error handler</a><br>
  </li>
  <li><a href="#Effective_usage_of_a_user-defined_error_">Effective
usage of a user-defined error handler</a></li>
  <li><a href="#Finalization_and_cleanup_">Finalization and cleanup</a></li>
  <li><a href="#The_list_of_error_code_">List of Error Code</a><br>
  </li>
</ul>
<ul>
</ul>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
</div>
</div>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
<br>
</div>
</body>
</html>
